package com.enterprise.controller.manage;

import java.util.List;

import javax.servlet.http.HttpServletRequest;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.enterprise.controller.BaseController;
import com.enterprise.entity.Logo;
import com.enterprise.entity.PageConfig;
import com.enterprise.service.LogoService;
import com.enterprise.service.Services;

@Controller
@RequestMapping("/manage/logo/")
public class LogoAction extends BaseController<Logo>{
	
	private static final String page_toList = "/manage/logo/logoList";
	private static final String page_toAdd = "/manage/logo/logoEdit";
	private static final String page_toEdit = "/manage/logo/logoEdit";
	
	
	public LogoAction(){
		super.page_toList = page_toList;
		super.page_toAdd = page_toAdd;
		super.page_toEdit = page_toEdit;
	}


	@Autowired
	LogoService logoService;
	
	@Override
	public Services<Logo> getService() {
		// TODO Auto-generated method stub
		return logoService;
	}
	
	
	@Override
	public String selectList(HttpServletRequest request, Logo logo){	
		List<Logo> logoList = logoService.selectList(logo);
		request.setAttribute("logoList", logoList);
		return page_toList;
		
	}
}
